#ifndef __baker_BasicOccluder_h__
#define __baker_BasicOccluder_h__

#include "Occluder.h"
#include "Array.h"

namespace baker
{
    /** A Basic Occluder implementation using bute-force intersection-testing approach.
    */
    class BasicOccluder : public IOccluder
    {
    public:
        BasicOccluder();

        virtual ~BasicOccluder();

        /** @sa IOccluder
        */
        virtual void addVertex( const Vec3 & vec3 );

        /** @sa IOccluder
        */
        virtual void addFace( guint v0
                            , guint v1
                            , guint v2
                            );

        /** @sa IOccluder
        */
        virtual void build();

        /** @sa IOccluder
        */
        virtual bool hitTestFast( const Ray3 & ray );

        /** @sa IOccluder
        */
        virtual void hitTestFull( HitState & hitState
                                , const Ray3 & ray
                                );

    private:
        Array<Vec3>     mVerts;
        Array<guint>    mFaces;

    };
}

#endif  // __baker_BasicOccluder_h__
